<%--<%@ taglib prefix="tbe" uri="http://iris.egrantTag.com/jsp/estl/core" %>--%>
<%@ taglib uri="/WEB-INF/tableexcel.tld" prefix="tbe"%>
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@ include file="/common/taglibs.jsp" %>
<x:parse xml="${param.xmlstr}" var="xmlData"/>




<script type="text/javascript">


	//控制导入表格的样式

	var cultivations_head_option = [
		{
			'name' : 'zh_name',
			'zhName' : '姓名',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'publishing_date',
			'zhName' : '毕业时间',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'thesis_title',
			'zhName' : '研究方向',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'thesis_title',
			'zhName' : '毕业论文题目',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'instructor',
			'zhName' : '指导教师',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'page',
			'zhName' : '附件佐证材料页码',
			'align' : 'left',
			'width' : '4'
		}
	];
	var titles_head_option = [
		{
			'name' : 'zh_name',
			'zhName' : '姓名',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'acquisition_year',
			'zhName' : '获得年度',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'promotion',
			'zhName' : '职称提升、人才类型',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'page',
			'zhName' : '附件佐证材料页码',
			'align' : 'left',
			'width' : '4'
		}
	];
	var guests_head_option = [
		{
			'name' : 'zh_name',
			'zhName' : '姓名',
			'align' : 'left',
			'width' : '4'
		}, {
			'name' : 'gender',
			'zhName' : '性别',
			'align' : 'left',
			'width' : '4'
		}, {
			'name' : 'birthday',
			'zhName' : '出生年月',
			'align' : 'center',
			'width' : '4',
		},
		{
			'name' : 'prof_title',
			'zhName' : '职称',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'major_work',
			'zhName' : '研究领域',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'work_org',
			'zhName' : '工作单位',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'page',
			'zhName' : '附件佐证材料页码',
			'align' : 'left',
			'width' : '4'
		}
	];
	var scienceTechnology_head_option = [
		{
			'name' : 'zh_name',
			'zhName' : '姓名',
			'align' : 'left',
			'width' : '4'
		}, {
			'name' : 'gender',
			'zhName' : '性别',
			'align' : 'left',
			'width' : '4'
		}, {
			'name' : 'birthday',
			'zhName' : '出生年月',
			'align' : 'center',
			'width' : '4',
		},
		{
			'name' : 'prof_title',
			'zhName' : '职称',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'major_work',
			'zhName' : '研究方向',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'degree',
			'zhName' : '最高学位',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'working_time',
			'zhName' : '在实验室工作期限',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'work',
			'zhName' : '实验室职务',
			'align' : 'left',
			'width' : '4'
		},
		{
			'name' : 'remarks',
			'zhName' : '备注',
			'align' : 'left',
			'width' : '4'
		}
	];


	/**
	 * 导入字段验证
	 * @type {*[]}
	 */

	var cultivations_validate_option = [
		{
			'name' : 'zh_name',
			'isValid' : true,
			'rules' : [ "required : true","maxStrLength : 99" ]
		},
		{
			'name' : 'publishing_date',
			'isValid' : true,
			'rules' : [
				"required : true",
				"isDate : true"
			]
		},

		{
			'name' : 'research_direction',
			'isValid' : true,
			'rules' : [ "required : true","maxStrLength : 99"]
		},
		{
			'name' : 'thesis_title',
			'isValid' : true,
			'rules' : [ "required : true","maxStrLength : 99"]
		},
		{
			'name' : 'instructor',
			'isValid' : true,
			'rules' : [ "required : true","maxStrLength : 99"]
		},
		{
			'name' : 'page',
			'isValid' : true,
			'rules' : [
				"required : true",
				"maxStrLength : 99"
			]
		}
	];
	var titles_validate_option = [
		{
			'name' : 'zh_name',
			'isValid' : true,
			'rules' : [ "required : true","maxStrLength : 99" ]
		},
		{
			'name' : 'acquisition_year',
			'isValid' : true,
			'rules' : [ "required : true","isYear : true"]
		},

		{
			'name' : 'promotion',
			'isValid' : true,
			'rules' : [ "required : true","maxStrLength : 99"]
		},
		{
			'name' : 'page',
			'isValid' : true,
			'rules' : [
				"required : true",
				"maxStrLength : 99"
			]
		}
	];

	var guests_validate_option = [
		{
			'name' : 'zh_name',
			'isValid' : true,
			'rules' : [ "required : true","maxStrLength : 99" ]
		}, {
			'name' : 'gender',
			'isValid' : true,
			'rules' : [ "required : true" ]
		}, {
			'name' : 'birthday',
			'isValid' : true,
			'rules' : [ "required : true", "isDate : true" ]
		},
		{
			'name' : 'prof_title',
			'isValid' : true,
			'rules' : [ "required : true","maxStrLength : 99" ]
		},
		{
			'name' : 'major_work',
			'isValid' : true,
			'rules' : [ "required : true","maxStrLength : 100" ]
		},

		{
			'name' : 'work_org',
			'isValid' : true,
			'rules' : [ "required : true","maxStrLength : 99"]
		},
		{
			'name' : 'page',
			'isValid' : true,
			'rules' : [
				"required : true",
				"maxStrLength : 99"
			]
		}
	];
	var scienceTechnology_validate_option = [
		{
			'name' : 'zh_name',
			'isValid' : true,
			'rules' : [ "required : true","maxStrLength : 99" ]
		}, {
			'name' : 'gender',
			'isValid' : true,
			'rules' : [ "required : true" ]
		}, {
			'name' : 'birthday',
			'isValid' : true,
			'rules' : [ "required : true", "isDate : true" ]
		},
		{
			'name' : 'prof_title',
			'isValid' : true,
			'rules' : [ "required : true","maxStrLength : 99" ]
		},
		{
			'name' : 'major_work',
			'isValid' : true,
			'rules' : [ "required : true","maxStrLength : 99" ]
		},
		{
			'name' : 'degree',
			'isValid' : true,
			'rules' : [ "required : true" ]
		},
		{
			'name' : 'working_time',
			'isValid' : true,
			'rules' : [ "required : true","maxStrLength : 99" ]
		},
		{
			'name' : 'work',
			'isValid' : true,
			'rules' : [ "required : true","maxStrLength : 99"]
		},
		{
			'name' : 'remarks',
			'isValid' : true,
			'rules' : [
				"required : false",
				"maxStrLength : 99"
			]
		}
	];





</script>

<div class="t_bar">
	1、固定人员名单（按研究方向依次填写）（限99条）
</div>
<table id="scienceTechnology" cellpadding="0" class="table01 t_css" width="100%" border="0" cellpadding="0"
	   style="*border-bottom: #a1c0dc 1px solid;table-layout: fixed;">
	<col width="5%"/>
	<col width="5%"/>
	<col width="9%"/>
	<col width="7%"/>
	<col width="15%"/>
	<col width="14%"/>
	<col width="10%"/>
	<col width="9%"/>
	<col width="10%"/>
	<col width="10%"/>
	<col width="10%"/>
	<thead>
	<tr style="border:1px solid #B7D1E6">
		<th class="TblHead" align="center">选择</th>
		<th class="TblHead" align="center">序号</th>
		<th class="TblHead" align="center">姓名</th>
		<th class="TblHead" align="center">性别</th>
		<th class="TblHead" align="center">出生日期</th>
		<th class="TblHead" align="center">职称</th>
		<th class="TblHead" align="center">研究方向</th>
		<th class="TblHead" align="center">最高学位</th>
		<th class="TblHead" align="center">在实验室工作期限</th>
		<th class="TblHead" align="center">实验室职务</th>
		<th class="TblHead" align="center">备注</th>
	</tr>

	</thead>
	<tbody>
	<tr style="display:none" align="center">
		<td align="center">
			<input type="radio" class="radiobutton" name="selScienceTechnology">
		</td>
		<td align="center">
			<span name="science_technologys|science_technology[0]@seq_no">[index]</span>
		</td>
		<td align="center">
			<input type="text" name="science_technologys|science_technology[0]|zh_title" label="姓名" class=" required input_text "
				   maxlength="99" style="width:80%"/>
		</td>
		<td align="center">
			<cpt:select id="gender[index]"  key="gender1"  name="gender"  onChange="initControlValue(this.id);" style="width: 85%;" cacheable="true"></cpt:select>
			<input type="hidden" name="science_technologys|science_technology[0]|gender_value"  class="required" value="" label="性别">
			<input type="hidden" name="science_technologys|science_technology[0]|gender_name" value="">
		</td>
		<td align="center">
			<cpt:date id="other1_birthday[index]"
					  name="science_technologys|science_technology[0]|birthday"
					  label="出生日期" size="12" className="required date beforeToday " ></cpt:date>
		</td>
		<td align="center">
			<input type="hidden" name="science_technologys|science_technology[0]|prof_title2_name" />
			<input type="hidden" name="science_technologys|science_technology[0]|prof_title2_value" label="职称" class="required"/>
			<cpt:tree key="prof_title" width="60%" cacheable="false" readonly="true" value="" id="prof_title2_[index]" name="prof_title"  showPattern="all" shieldPattern="-1" onClick="initProfTitleTreeValueExt"   label="职称" />
				<%--<input type="text" name="science_technologys|science_technology[0]|prof_title" label="职称" class=" required input_text "
					   maxlength="99" style="width:80%"/>--%>
		</td>
		<td align="center">
			<input type="text" name="science_technologys|science_technology[0]|major_work" label="研究方向" maxlength="99" class="required"  style="width: 80%;"/>
		</td>
		<td align="center">
			<cpt:select id="degree_[index]" key="degree"  name="degree" className="selectWidth2 required"
						label="最高学位" onChange="initControlValue(this.id)" value=""  style="width:85%"></cpt:select>
			<input type="hidden" name="science_technologys|science_technology[0]|degree_value" value=""/>
			<input type="hidden" name="science_technologys|science_technology[0]|degree_name" value=""/>
		</td>
		<td align="center">
			<input type="text" name="science_technologys|science_technology[0]|working_time" maxlength="99" label="在实验室工作期限" class="required" style="width: 80%;"/>
		</td>
		<td align="center">
			<input type="text" name="science_technologys|science_technology[0]|work" label="实验室职务" class=" required input_text "
				   maxlength="99" style="width:80%"  />
		</td>
		<td align="center">
			<input type="text" name="science_technologys|science_technology[0]|remarks" label="备注" class="input_text "
				   maxlength="99" style="width:80%"/>
		</td>
	</tr>

	<c:set value="0" var="index" scope="page"/>
	<x:forEach select="$xmlData/data/science_technologys/science_technology" var="science_technology">

		<c:choose>
			<c:when test="${index<10}"><c:set value="0" var="flag" scope="page"/></c:when>
			<c:otherwise><c:set value="" var="flag" scope="page"/></c:otherwise>
		</c:choose>
		<tr align="center">
			<td align="center">
				<input type="radio" class="radiobutton" name="selScienceTechnology">
			</td>
			<td align="center">
				<span name="science_technologys/science_technology[${flag}${index}]@seq_no"><x:out select="$science_technology/@seq_no"/></span>
			</td>
			<td align="center">
				<input type="text" name="science_technologys/science_technology[${flag}${index}]/zh_title" label="姓名" class=" required input_text "
					   maxlength="99" style="width:80%" value="<x:out select="$science_technology/zh_title"/>"/>
			</td>
			<c:set var="gender_name"><x:out select="$science_technology/gender_name" /></c:set>
			<c:if test="${empty gender_name }">
				<c:set var="gender_value"><x:out select="$science_technology/gender_value" /></c:set>
				<c:set var="gender_name">
					<c:if test="${gender_value=='M' }">男</c:if>
					<c:if test="${gender_value=='F' }">女</c:if>
				</c:set>
			</c:if>
			<td align="center">
				<c:set var="gender1"><x:out select="$science_technology/gender_value"/></c:set>
				<cpt:select id="gender${index}"  key="gender1"  name="gender" value="${gender1}"  onChange="initControlValue(this.id);" style="width: 85%;"></cpt:select>
				<input type="hidden" name="science_technologys/science_technology[${flag}${index}]/gender_value"  class="required" value="<x:out select="$science_technology/gender_value"/>" label="性别">
				<input type="hidden" name="science_technologys/science_technology[${flag}${index}]/gender_name" value="${gender_name }">
			</td>
			<td align="center">
				<c:set var="birthday"><x:out select="$science_technology/birthday"/></c:set>
				<cpt:date id="other1_birthday${index+1}"
						  name="science_technologys/science_technology[${flag}${index}]/birthday"  value="${birthday }"
						  label="出生日期" size="12" className="required date beforeToday "></cpt:date>
			</td>
			<td align="center">
				<c:set var="prof_title_value"><x:out select="$science_technology/prof_title2_value" /></c:set>
				<c:set var="prof_title_name"><x:out select="$science_technology/prof_title2_name" /></c:set>
				<c:set var="prof_title">{'id':'${prof_title_value}','name':'${prof_title_name}'}</c:set>
				<input type="hidden" name="science_technologys/science_technology[${flag}${index}]/prof_title2_name" value="${prof_title_name}"/>
				<input type="hidden" name="science_technologys/science_technology[${flag}${index}]/prof_title2_value" label="职称" class="required" value="${prof_title_value}"/>
				<cpt:tree key="prof_title" width="60%" cacheable="false" readonly="true" id="prof_title2_${index}" name="prof_title" value="${prof_title}" showPattern="all" shieldPattern="-1" onClick="initProfTitleTreeValueExt"   label="职称" />
					<%--<input type="text" name="science_technologys/science_technology[${flag}${index}]/prof_title" label="职称" class=" required input_text "
						   maxlength="99" style="width:80%" value="<x:out select="$science_technology/prof_title"/>"/>--%>
			</td>
			<td align="center">
				<input type="text" name="science_technologys/science_technology[${flag}${index}]/major_work" label="研究方向" maxlength="99" class="required"
					   style="width: 80%;" value="<x:out select="$science_technology/major_work"/>"/>
			</td>
			<td align="center">
				<c:set var="degree"><x:out select="$science_technology/degree_value" /></c:set>
				<cpt:select id="degree_${index}" key="degree"  name="degree"  value="${degree}" className="selectWidth2 required"
							label="最高学位" style="width:85%" onChange="initControlValue(this.id)"></cpt:select>
				<input type="hidden" name="science_technologys/science_technology[${flag}${index}]/degree_value" class="required" value="<x:out select="$science_technology/degree_value" />"/>
				<input type="hidden" name="science_technologys/science_technology[${flag}${index}]/degree_name" value="<x:out select="$science_technology/degree_name" />"/>
			</td>
			<td align="center">
				<input type="text" name="science_technologys/science_technology[${flag}${index}]/working_time" label="在实验室工作期限" class="required"
					   maxlength="99"  style="width: 80%;" value="<x:out select="$science_technology/working_time"/>"/>
			</td>
			<td align="center">
				<input type="text" name="science_technologys/science_technology[${flag}${index}]/work" label="实验室职务" class=" required input_text "
					   maxlength="99" style="width:80%" value="<x:out select="$science_technology/work"/>"/>
			</td>
			<td align="center">
				<input type="text" name="science_technologys/science_technology[${flag}${index}]/remarks" label="备注" class="input_text required"
					   maxlength="99" style="width:80%" value="<x:out select="$science_technology/remarks"/>"/>
			</td>
		</tr>
		<c:set value="${index+1}" var="index" scope="page"/>
	</x:forEach>
	</tbody>
	<script type="text/javascript">
		showAllDateTag("scienceTechnology");
	</script>
</table>
<table width="98%" align="center" border="0">
	<tr >
		<td >
			<input class="button_02" name="cmdAddbefore" type=button value="添加"
				   onclick="if(checkTabLimit('scienceTechnology',99,'固定人员名单最多只能添加99条')){addNewRow('scienceTechnology');showDateTag('scienceTechnology');try{top.resizeFrame();}catch(e){};}">
			<input class="button_02" name="cmdMovePrev" type=button value="上移"
				   onclick="movePrev('scienceTechnology','selScienceTechnology')">
			<input class="button_02" name="cmdMoveNext" type=button value="下移"
				   onclick="moveNext('scienceTechnology','selScienceTechnology')">
			<input class="button_02" name="cmddel" type=button value="删除"
				   onclick="deleteSelectedRow('scienceTechnology','固定人员名单')">
			<tbe:tableToExcel tableTitle="固定人员名单" type="proposal" tableId="scienceTechnology" keyCode="${posCode}" maxSize="99" validateOption="scienceTechnology_validate_option" headOption="scienceTechnology_head_option" buttonClass="button_02"/>

		</td>
	</tr>
</table>
<br/>




<div class="t_bar">
	2、客座人员名单（限填5项）
</div>
<table id="guests" cellpadding="0" class="table01 t_css" width="100%" border="0" cellpadding="0"
	   style="*border-bottom: #a1c0dc 1px solid;table-layout: fixed;">
	<col width="5%"/>
	<col width="5%"/>
	<col width="10%"/>
	<col width="10%"/>
	<col width="16%"/>
	<col width="14%"/>
	<col width="13%"/>
	<col width="12%"/>
	<col width="15%"/>
	<thead>
	<tr style="border:1px solid #B7D1E6">
		<th class="TblHead" align="center">选择</th>
		<th class="TblHead" align="center">序号</th>
		<th class="TblHead" align="center">姓名</th>
		<th class="TblHead" align="center">性别</th>
		<th class="TblHead" align="center">出生日期</th>
		<th class="TblHead" align="center">职称</th>
		<th class="TblHead" align="center">研究领域</th>
		<th class="TblHead" align="center">工作单位</th>
		<th class="TblHead" align="center">附件佐证材料页码</th>

	</tr>

	</thead>
	<tbody>
	<tr style="display:none" align="center">
		<td align="center">
			<input type="radio" class="radiobutton" name="selGuests">
		</td>
		<td align="center">
			<span name="guests|guest[0]@seq_no">[index]</span>
		</td>
		<td align="center">
			<input type="text" name="guests|guest[0]|zh_title" label="姓名" class=" required input_text "
				   maxlength="99" style="width:80%"/>
		</td>
		<td align="center">
			<cpt:select id="genders[index]"  key="gender1"  name="gender"  onChange="initControlValue(this.id);" style="width: 85%;"></cpt:select>
			<input type="hidden" name="guests|guest[0]|gender_value"  class="required" value="" label="性别">
			<input type="hidden" name="guests|guest[0]|gender_name" value="">
		</td>
		<td align="center">
			<cpt:date id="other_birthday[index]"
					  name="guests|guest[0]|birthday"
					  label="出生日期" size="12" className="required date beforeToday" ></cpt:date>
		</td>
		<td align="center">
			<input type="hidden" name="guests|guest[0]|prof_title1_name" />
			<input type="hidden" name="guests|guest[0]|prof_title1_value" label="职称" class="required"/>
			<cpt:tree key="prof_title" width="60%" cacheable="false" readonly="true" value="" id="prof_title1_[index]" name="prof_title"  showPattern="all" shieldPattern="-1" onClick="initProfTitleTreeValueExt"   label="职称" />
				<%--<input type="text" name="guests|guest[0]|prof_title" label="职称" class=" required input_text "
					   maxlength="99" style="width:80%"/>--%>
		</td>
		<td align="center">
			<input type="text" name="guests|guest[0]|major_work" label="研究领域" maxlength="100" class="required"  style="width: 80%;"/>
		</td>
		<td align="center">
			<input type="text" name="guests|guest[0]|work_org" label="工作单位" class=" required input_text "
				   maxlength="99" style="width:80%"  />
		</td>
		<td align="center">
			<input type="text" name="guests|guest[0]|page" label="附件佐证材料页码" class="input_text required"
				   maxlength="99" style="width:80%"/>
		</td>
	</tr>

	<c:set value="0" var="index" scope="page"/>
	<x:forEach select="$xmlData/data/guests/guest" var="guest">

		<c:choose>
			<c:when test="${index<10}"><c:set value="0" var="flag" scope="page"/></c:when>
			<c:otherwise><c:set value="" var="flag" scope="page"/></c:otherwise>
		</c:choose>
		<tr align="center">
			<td align="center">
				<input type="radio" class="radiobutton" name="selGuests">
			</td>
			<td align="center">
				<span name="guests/guest[${flag}${index}]@seq_no"><x:out select="$guest/@seq_no"/></span>
			</td>
			<td align="center">
				<input type="text" name="guests/guest[${flag}${index}]/zh_title" label="姓名" class=" required input_text "
					   maxlength="99" style="width:80%" value="<x:out select="$guest/zh_title"/>"/>
			</td>
			<c:set var="gender_name"><x:out select="$guest/gender_name" /></c:set>
			<c:if test="${empty gender_name }">
				<c:set var="gender_value"><x:out select="$guest/gender_value" /></c:set>
				<c:set var="gender_name">
					<c:if test="${gender_value=='M' }">男</c:if>
					<c:if test="${gender_value=='F' }">女</c:if>
				</c:set>
			</c:if>
			<td align="center">
				<c:set var="gender1"><x:out select="$guest/gender_value"/></c:set>
				<cpt:select id="genders${index}"  key="gender1"  name="gender" value="${gender1}"  onChange="initControlValue(this.id);" style="width: 85%;" cacheable="true"></cpt:select>
				<input type="hidden" name="guests/guest[${flag}${index}]/gender_value"  class="required" value="<x:out select="$guest/gender_value"/>" label="性别">
				<input type="hidden" name="guests/guest[${flag}${index}]/gender_name" value="${gender_name }">
			</td>
			<td align="center">
				<c:set var="birthday"><x:out select="$guest/birthday"/></c:set>
				<cpt:date id="other_birthday${index+1}"
						  name="guests/guest[${flag}${index}]/birthday"  value="${birthday }"
						  label="出生日期" size="12" className="required date beforeToday "></cpt:date>
			</td>
			<td align="center">
				<c:set var="prof_title_value"><x:out select="$guest/prof_title1_value" /></c:set>
				<c:set var="prof_title_name"><x:out select="$guest/prof_title1_name" /></c:set>
				<c:set var="prof_title">{'id':'${prof_title_value}','name':'${prof_title_name}'}</c:set>
				<input type="hidden" name="guests/guest[${flag}${index}]/prof_title1_name" value="${prof_title_name}"/>
				<input type="hidden" name="guests/guest[${flag}${index}]/prof_title1_value" label="职称" class="required" value="${prof_title_value}"/>
				<cpt:tree key="prof_title" width="60%" cacheable="false" readonly="true" id="prof_title1_${index}" name="prof_title" value="${prof_title}" showPattern="all" shieldPattern="-1" onClick="initProfTitleTreeValueExt"   label="职称" />
					<%--<input type="text" name="guests/guest[${flag}${index}]/prof_title" label="职称" class=" required input_text "
						   maxlength="99" style="width:80%" value="<x:out select="$guest/prof_title"/>"/>--%>
			</td>
			<td align="center">
				<input type="text" name="guests/guest[${flag}${index}]/major_work" label="研究领域" maxlength="100" class="required"
					   style="width: 80%;" value="<x:out select="$guest/major_work"/>"/>
			</td>

			<td align="center">
				<input type="text" name="guests/guest[${flag}${index}]/work_org" label="工作单位" class=" required input_text "
					   maxlength="99" style="width:80%" value="<x:out select="$guest/work_org"/>"/>
			</td>
			<td align="center">
				<input type="text" name="guests/guest[${flag}${index}]/page" label="附件佐证材料页码" class="input_text required"
					   maxlength="99" style="width:80%" value="<x:out select="$guest/page"/>"/>
			</td>
		</tr>
		<c:set value="${index+1}" var="index" scope="page"/>
	</x:forEach>
	</tbody>
	<script type="text/javascript">
		showAllDateTag("scienceTechnology");
	</script>
</table>
<table width="98%" align="center" border="0">
	<tr >
		<td >
			<input class="button_02" name="cmdAddbefore" type=button value="添加"
				   onclick="if(checkTabLimit('guests',5,'客座人员名单最多只能添加5条')){addNewRow('guests');showDateTag('guests');try{top.resizeFrame();}catch(e){};}">
			<input class="button_02" name="cmdMovePrev" type=button value="上移"
				   onclick="movePrev('guests','selGuests')">
			<input class="button_02" name="cmdMoveNext" type=button value="下移"
				   onclick="moveNext('guests','selGuests')">
			<input class="button_02" name="cmddel" type=button value="删除"
				   onclick="deleteSelectedRow('guests','客座人员名单')">
			<tbe:tableToExcel tableTitle="客座人员名单" type="proposal" tableId="guests" keyCode="${posCode}" maxSize="5" validateOption="guests_validate_option" headOption="guests_head_option" buttonClass="button_02"/>

		</td>
	</tr>
</table>
<br/>
<div class="t_bar">
	3、固定人员职称提升、新增省级以上人才计划资助或荣誉称号情况（限填10项）
</div>
<table id="titles" cellpadding="0" class="table01 t_css" width="100%" border="0" cellpadding="0"
	   style="*border-bottom: #a1c0dc 1px solid;table-layout: fixed;">
	<col width="5%"/>
	<col width="5%"/>
	<col width="20%"/>
	<col width="20%"/>
	<col width="25%"/>
	<col width="25%"/>
	<thead>
	<tr style="border:1px solid #B7D1E6">
		<th class="TblHead" align="center">选择</th>
		<th class="TblHead" align="center">序号</th>
		<th class="TblHead" align="center">姓名</th>
		<th class="TblHead" align="center">获得年度</th>
		<th class="TblHead" align="center">职称提升、人才类型</th>
		<th class="TblHead" align="center">附件佐证材料页码</th>

	</tr>

	</thead>
	<tbody>
	<tr style="display:none" align="center">
		<td align="center">
			<input type="radio" class="radiobutton" name="seltitles">
		</td>
		<td align="center">
			<span name="titles|title[0]@seq_no">[index]</span>
		</td>
		<td align="center">
			<input type="text" name="titles|title[0]|zh_title" label="姓名" class=" required input_text "
				   maxlength="99" style="width:80%"/>
		</td>

		<td align="center">
			<input type="text" name="titles|title[0]|acquisition_year" label="获得年度" onfocus="InitInput.setNumber(this,4,0,0)" class="required "  style="width: 80%;"/>
		</td>
		<td align="center">
			<input type="text" name="titles|title[0]|promotion" label="职称提升、人才类型" class=" required input_text "
				   maxlength="99" style="width:80%"  />
		</td>
		<td align="center">
			<input type="text" name="titles|title[0]|page" label="附件佐证材料页码" class="input_text required"
				   maxlength="99" style="width:80%"/>
		</td>
	</tr>

	<c:set value="0" var="index" scope="page"/>
	<x:forEach select="$xmlData/data/titles/title" var="title">

		<c:choose>
			<c:when test="${index<10}"><c:set value="0" var="flag" scope="page"/></c:when>
			<c:otherwise><c:set value="" var="flag" scope="page"/></c:otherwise>
		</c:choose>
		<tr align="center">
			<td align="center">
				<input type="radio" class="radiobutton" name="seltitles">
			</td>
			<td align="center">
				<span name="titles/title[${flag}${index}]@seq_no"><x:out select="$title/@seq_no"/></span>
			</td>
			<td align="center">
				<input type="text" name="titles/title[${flag}${index}]/zh_title" label="姓名" class=" required input_text "
					   maxlength="99" style="width:80%" value="<x:out select="$title/zh_title"/>"/>
			</td>

			<td align="center">
				<input type="text" name="titles/title[${flag}${index}]/acquisition_year" label="获得年度" onfocus="InitInput.setNumber(this,4,0,0)" class=" required input_text "
					   style="width:80%" value="<x:out select="$title/acquisition_year"/>"/>
			</td>
			<td>
				<input type="text" name="titles/title[${flag}${index}]/promotion" label="职称提升、人才类型" maxlength="99" class="required"
					   style="width: 80%;" value="<x:out select="$title/promotion"/>"/>
			</td>
			<td align="center">
				<input type="text" name="titles/title[${flag}${index}]/page" label="附件佐证材料页码" class="input_text required"
					   maxlength="99" style="width:80%" value="<x:out select="$title/page"/>"/>
			</td>
		</tr>
		<c:set value="${index+1}" var="index" scope="page"/>
	</x:forEach>
	</tbody>
	<script type="text/javascript">
		showAllDateTag("scienceTechnology");
	</script>
</table>
<table width="98%" align="center" border="0">
	<tr >
		<td >
			<input class="button_02" name="cmdAddbefore" type=button value="添加"
				   onclick="if(checkTabLimit('titles',10,'固定人员职称提升、新增省级以上人才计划资助或荣誉称号情况最多只能添加10条')){addNewRow('titles');showDateTag('titles');try{top.resizeFrame();}catch(e){};}">
			<input class="button_02" name="cmdMovePrev" type=button value="上移"
				   onclick="movePrev('titles','seltitles')">
			<input class="button_02" name="cmdMoveNext" type=button value="下移"
				   onclick="moveNext('titles','seltitles')">
			<input class="button_02" name="cmddel" type=button value="删除"
				   onclick="deleteSelectedRow('titles','固定人员职称提升、新增省级以上人才计划资助或荣誉称号情况')">
			<tbe:tableToExcel tableTitle="固定人员职称提升、新增省级以上人才计划资助或荣誉称号情况" type="proposal" tableId="titles" keyCode="${posCode}" maxSize="10" validateOption="titles_validate_option" headOption="titles_head_option" buttonClass="button_02"/>

		</td>
	</tr>
</table>
<br/>
<div class="t_bar">
	4、研究生培养情况（限99条）
</div>
<table id="cultivations" cellpadding="0" class="table01 t_css" width="100%" border="0" cellpadding="0"
	   style="*border-bottom: #a1c0dc 1px solid;table-layout: fixed;">
	<col width="5%"/>
	<col width="5%"/>
	<col width="15%"/>
	<col width="15%"/>
	<col width="15%"/>
	<col width="15%"/>
	<col width="15%"/>
	<col width="15%"/>
	<thead>
	<tr style="border:1px solid #B7D1E6">
		<th class="TblHead" align="center">选择</th>
		<th class="TblHead" align="center">序号</th>
		<th class="TblHead" align="center">姓名</th>
		<th class="TblHead" align="center">毕业时间</th>
		<th class="TblHead" align="center">研究方向</th>
		<th class="TblHead" align="center">毕业论文题目</th>
		<th class="TblHead" align="center">指导教师</th>
		<th class="TblHead" align="center">附件佐证材料页码</th>

	</tr>

	</thead>
	<tbody>
	<tr style="display:none" align="center">
		<td align="center">
			<input type="radio" class="radiobutton" name="selcultivations">
		</td>
		<td align="center">
			<span name="cultivations|cultivation[0]@seq_no">[index]</span>
		</td>
		<td align="center">
			<input type="text" name="cultivations|cultivation[0]|zh_title" label="姓名" class=" required input_text "
				   maxlength="99" style="width:80%"/>
		</td>
		<td>
			<input id="cultivation_publishing_date_[0]" name="cultivations|cultivation[0]|publishing_date" label="毕业时间"
				   class="required input_text date beforeToday" style="width:70%"/>
		</td>
		<td align="center">
			<input type="text" name="cultivations|cultivation[0]|research_direction" label="研究方向" maxlength="99" class="required"  style="width: 80%;"/>
		</td>
		<td align="center">
			<input type="text" name="cultivations|cultivation[0]|thesis_title" label="毕业论文题目" class=" required input_text "
				   maxlength="99" style="width:80%"  />
		</td>
		<td align="center">
			<input type="text" name="cultivations|cultivation[0]|instructor" label="指导教师" class=" required input_text "
				   maxlength="99" style="width:80%"  />
		</td>
		<td align="center">
			<input type="text" name="cultivations|cultivation[0]|page" label="附件佐证材料页码" class="input_text required"
				   maxlength="99" style="width:80%"/>
		</td>
	</tr>

	<c:set value="0" var="index" scope="page"/>
	<x:forEach select="$xmlData/data/cultivations/cultivation" var="cultivation">

		<c:choose>
			<c:when test="${index<10}"><c:set value="0" var="flag" scope="page"/></c:when>
			<c:otherwise><c:set value="" var="flag" scope="page"/></c:otherwise>
		</c:choose>
		<tr align="center">
			<td align="center">
				<input type="radio" class="radiobutton" name="selcultivations">
			</td>
			<td align="center">
				<span name="cultivations/cultivation[${flag}${index}]@seq_no"><x:out select="$cultivation/@seq_no"/></span>
			</td>
			<td align="center">
				<input type="text" name="cultivations/cultivation[${flag}${index}]/zh_title" label="姓名" class=" required input_text "
					   maxlength="99" style="width:80%" value="<x:out select="$cultivation/zh_title"/>"/>
			</td>
			<td align="center" >
				<c:set var="publishing_date"><x:out select="$cultivation/publishing_date"/></c:set>
				<input id="cultivation_publishing_date_[${flag}${index}]" name="cultivations/cultivation[${flag}${index}]/publishing_date" label="毕业时间"
					   class="required input_text date beforeToday" style="width:70%" value="${publishing_date}"/>
			</td>

			<td align="center">
				<input type="text" name="cultivations/cultivation[${flag}${index}]/research_direction" label="研究方向" class=" required input_text "
					   maxlength="99" style="width:80%" value="<x:out select="$cultivation/research_direction"/>"/>
			</td>
			<td>
				<input type="text" name="cultivations/cultivation[${flag}${index}]/thesis_title" label="毕业论文题目" maxlength="99" class="required"
					   style="width: 80%;" value="<x:out select="$cultivation/thesis_title"/>"/>
			</td>
			<td>
				<input type="text" name="cultivations/cultivation[${flag}${index}]/instructor" label="指导教师" maxlength="99" class="required"
					   style="width: 80%;" value="<x:out select="$cultivation/instructor"/>"/>
			</td>
			<td align="center">
				<input type="text" name="cultivations/cultivation[${flag}${index}]/page" label="附件佐证材料页码" class="input_text required"
					   maxlength="99" style="width:80%" value="<x:out select="$cultivation/page"/>"/>
			</td>
		</tr>
		<c:set value="${index+1}" var="index" scope="page"/>
	</x:forEach>
	</tbody>
	<script type="text/javascript">
		showAllDateTag("cultivations");
	</script>
</table>
<table width="98%" align="center" border="0">
	<tr >
		<td >
			<input class="button_02" name="cmdAddbefore" type=button value="添加"
				   onclick="if(checkTabLimit('cultivations',99,'研究生培养情况最多只能添加99条')){addNewRow('cultivations');showDateTag('cultivations');try{top.resizeFrame();}catch(e){};}">
			<input class="button_02" name="cmdMovePrev" type=button value="上移"
				   onclick="movePrev('cultivations','selcultivations')">
			<input class="button_02" name="cmdMoveNext" type=button value="下移"
				   onclick="moveNext('cultivations','selcultivations')">
			<input class="button_02" name="cmddel" type=button value="删除"
				   onclick="deleteSelectedRow('cultivations','研究生培养情况')">
			<tbe:tableToExcel tableTitle="研究生培养情况" type="proposal" tableId="cultivations" keyCode="${posCode}" maxSize="99" validateOption="cultivations_validate_option" headOption="cultivations_head_option" buttonClass="button_02"/>

		</td>
	</tr>
</table>
<br/>



<script type="text/javascript">


	/**
	 * 上移行
	 * @param tblId
	 * @returns {Boolean}
	 */
	function movePrev2(tblId, selName) {
		if (!selName)
			selName = "";
		if ($("#" + tblId + " :radio[name*='" + selName + "']:checked").length == 0) {
			scmWarn(irisNotes.prevWarn);
			return false;
		}
		if ($("#" + tblId + " tr").length <= 2)
			return false;
		var trChecked = $("#" + tblId + " :radio[name*='" + selName + "']:checked")
				.parents("tr").first();// 取得被选中的行
		var trPrev = trChecked.prev();// 取得上一行
		var index = trChecked.get(0).rowIndex;// 获得行号
		if (index <= 2) {// 如果是第一行
			scmWarn(irisNotes.tabelMoveWarn1);
			return false;
		}
		//trChecked.remove();
		trPrev.before(trChecked);
		trChecked.find(":radio[name*='" + selName + "']").attr("checked", 'true');
		refreshRowINdex2(tblId);
	}

	/**
	 * 下移行
	 * @param tblId
	 * @returns {Boolean}
	 */
	function moveNext2(tblId, selName) {
		if (!selName)
			selName = "";
		if ($("#" + tblId + " :radio[name*='" + selName + "']:checked").length == 0) {
			scmWarn(irisNotes.nextWarn);
			return false;
		}
		if ($("#" + tblId + " tr").length <= 2) {
			return false;
		}
		var trChecked = $("#" + tblId + " :radio[name*='" + selName + "']:checked")
				.parents("tr").first();// 取得被选中的行
		var trNext = trChecked.next();
		var index = trChecked.get(0).rowIndex;// 获得行号
		if (index == $("#" + tblId + " tr").length - 1) {// 如果是第一行
			scmWarn(irisNotes.tabelMoveWarn2);
			return false;
		}
		//trChecked.remove();
		trNext.after(trChecked);
		trChecked.find(":radio[name*='" + selName + "']").attr("checked", "true");
		refreshRowINdex2(tblId);
	}

	/**
	 * 重新计算行号
	 * @param tblId
	 */
	function refreshRowINdex2(tblId) {
		//重新计算行号
		$("#" + tblId + " tr").each(function () {
					var seq = $(this).get(0).rowIndex;//获得行数
					if (tblId == 'tblPaperWorks') {
						seq = seq - 1;
					}
					if (seq > 1) {//如果有行  显示时display行不计入类，故只减1
						seq = seq - 1;
						var seq_no = $(this).find("[name$='seq_no']");
						if (seq_no.is("span"))
							seq_no.html(seq);
						else
							seq_no.val(seq);

						seq = "" + (seq - 1);
						if (seq.length == 1)
							seq = "0" + seq;
						//替换相应的name参数的seq
						$(this).find("input,span,textarea,select").each(function () {
							var name = $(this).attr("name");
							if (name != null && name != "") {
								name = name.replace(/\[\d*\]/g, "[" + seq + "]");
								$(this).attr("name", name);
							}
							/* var id=$(this).attr("id");
                            if(id!=null&&id!=""){
                                id=id.replace(/\[\d*\]/g,"["+seq+"]");
                                $(this).attr("id",id);
                                id=id.replace(/\d+/g,""+seq+"");
                                $(this).attr("id",id);
                            } */
							var className = $(this).attr("class");
							if (className != null && className != "") {
								className = className.replace(/\[\d*\]/g, "[" + seq + "]");
								$(this).attr("class", className);
							}
						});
					}
				}
		);

	}


	/**
	 * 删除一行
	 * @param radioId
	 */
	function deleteSelectedRow2(tableId, message, nummin, warnMsg, selName) {
		if (!selName) selName = "";
		var tr = $("#" + tableId + " :radio[name*='" + selName + "']:checked").parents("tr");
		if (nummin == null)
			nummin = 0;
		var length = tr.length;
		if (tr.length == 0)
			tr = $("#" + tableId + " tr").filter(":last");
		else if (tr.length > 1)
			tr = tr.first();

		if (tr.get(0).rowIndex - 1 == nummin) {
			scmWarn(irisNotes.delWarn1);
			return false;
		}
		if (length == 0) {

			scmWarn(irisNotes.delWarn2);

			return false;
		}
		if (!confirm(messageTip.deleteTip + message + "？"))
			return false;
		tr.remove();
		refreshRowINdex2(tableId);
		return true;
		setSubmitOrg();
	}
	function initProfTitleTreeValueExt(treeId, treeNode) {

		var inputId = treeId.substring(0, treeId.lastIndexOf('_'));
		if (!(treeNode && (treeNode.level > 0 || !treeNode.isParent))) {
			scmWarn($("#" + treeId).attr("label")
					+ messageTip.researchAreaInvalidDisciplineCode);
			if (treeNode.level == 0) {
				$("#" + treeId).val("");
				$("#" + treeId).parents("td").find("[name$='" + inputId + "_code'],[id$='" + inputId+ "_code']").val("");
				$("#" + treeId).parents("td").find("[name$='" + inputId + "_value'],[id$='" + inputId+ "_value']").val("");
				$("#" + treeId).parents("td").find("[name$='" + inputId + "_name'],[id$='" + inputId+ "_name']").val("");
			}
			return false;
		}
		var str = treeNode.name;
		var obj = treeNode.parentNode;
		while (obj != null) {
			obj = obj.parentNode;
		}
		$("#" + treeId).parents("td").find("[name$='" + inputId + "_code'],[id$='" + inputId+ "_code']").val(treeNode.id);
		$("#" + treeId).parents("td").find("[name$='" + inputId + "_value'],[id$='" + inputId+ "_value']").val(treeNode.id);
		$("#" + treeId).parents("td").find("[name$='" + inputId + "_name'],[id$='" + inputId+ "_name']").val(str);
	}

</script>
